package java实验六;

public class 程序二 {
    public static void main(String[] args) {
        String answers = "DDBBDD";
        char[] keys = {'D', 'B', 'A', 'C', 'D', 'E'};
        
        int correctCount = 0;
        for (int i = 0; i < answers.length(); i++) {
            if (answers.charAt(i) == keys[i]) {
                correctCount++;
            }
        }
        
        System.out.println("Student 0's correct count is " + correctCount);
    }
}
